//
//  ZLListCallBack.h
//  ZLCustomViews
//
//  Created by 科大 on 2024/6/20.
//

#ifndef ZLListCallBack_h
#define ZLListCallBack_h
#import <UIKit/UIKit.h>

typedef NSInteger(^ZLSectionNumber)(void);
typedef NSInteger(^ZLRowNumber)(NSInteger section);
typedef void(^ZLSelectCell)(NSIndexPath * _Nonnull indexPath);
typedef void(^ZLPageChange)(NSIndexPath * _Nonnull indexPath);

/// table
typedef CGFloat(^ZLCellHeight)(NSIndexPath * _Nonnull indexPath);
typedef UITableViewCell* _Nullable (^ZLIndexPathCell)(UITableView * _Nonnull tableview, NSIndexPath * _Nonnull indexPath);
typedef CGFloat(^ZLSectionHeaderFooterHeight)(NSInteger section);
typedef UIView* _Nullable(^ZLSectionHeaderFooter)(NSInteger section);

/// collection
typedef CGSize(^ZLItemSize)(NSIndexPath * _Nonnull indexPath);
typedef CGSize(^ZLHeaderFooterSize)(NSInteger section);
typedef CGFloat(^ZLSpacing)(NSInteger section);
typedef UICollectionViewCell* _Nullable (^ZLIndexPathItem)(UICollectionView * _Nonnull collectionView, NSIndexPath * _Nonnull indexPath);
typedef UICollectionReusableView* _Nullable (^ZLCSectionHeaderFooter)(UICollectionView * _Nonnull collectionView, NSIndexPath * _Nonnull indexPath);

#endif /* ZLListCallBack_h */
